package com.test.math;

public class FiboDemo {

    public static void main(String[] args) {
        printFibonacci(11);
    }

    public static void printFibonacci(int n){
        int a = 0, b = 1, c;
        System.out.print("Fibonacci Series of "+n+" numbers:");
        for(int i = 1; i <= n; i++){
            System.out.print(a+" ");
            c = a + b;
            a = b;
            b = c;
        }
    }
}
